package com.ourteam.product.requirement.dao;

import net.dao.BaseQueryBean;
import net.dao.BaseWhereCriterion;
import net.dao.IDataAccessInterface;

import org.apache.commons.lang.StringUtils;

import java.util.Arrays;
import java.util.List;
import java.util.Map;


/**
 * Template Name : DAO查询对象
 * Template Version : 1
 * Template Last Modfiy Date : Sat Aug 19 10:06:32 CST 2017
 * Auto Generate Date : 2018-05-03 16:45:28
  * Warning ! This file will be overwrite when regenerate !
  *
 */
public class ProductRoleDefineDAOQueryBean extends BaseQueryBean {
    public ProductRoleDefineDAOQueryBean() {
        super();
    }

    public ProductRoleDefineDAOQueryBean(BaseQueryBean aQueryBean) {
        super(aQueryBean);
    }

    public ProductRoleDefineDAOQueryBean(BaseQueryBean aQueryBean,
        Map tableReplaceMap) {
        super(aQueryBean, tableReplaceMap);
    }

    public Criteria createCriteria() {
        Criteria criteria = createCriteriaInternal();

        if (oredCriteria.size() == 0) {
            oredCriteria.add(criteria);
        }

        return criteria;
    }

    protected Criteria createCriteriaInternal() {
        return new Criteria(this);
    }

    public void addIdSelectProperty() {
        addIdSelectProperty("id");
    }

    public void addIdSelectProperty(String aAlias) {
        if (StringUtils.isNotBlank(aAlias)) {
            addSelectProperty(IProductRoleDefineDAO.Id, aAlias);
        } else {
            addSelectProperty(IProductRoleDefineDAO.Id, "id");
        }
    }

    public void addProductDefineIdSelectProperty() {
        addProductDefineIdSelectProperty("productDefineId");
    }

    public void addProductDefineIdSelectProperty(String aAlias) {
        if (StringUtils.isNotBlank(aAlias)) {
            addSelectProperty(IProductRoleDefineDAO.ProductDefineId, aAlias);
        } else {
            addSelectProperty(IProductRoleDefineDAO.ProductDefineId,
                "productDefineId");
        }
    }

    public void addRoleCodeSelectProperty() {
        addRoleCodeSelectProperty("roleCode");
    }

    public void addRoleCodeSelectProperty(String aAlias) {
        if (StringUtils.isNotBlank(aAlias)) {
            addSelectProperty(IProductRoleDefineDAO.RoleCode, aAlias);
        } else {
            addSelectProperty(IProductRoleDefineDAO.RoleCode, "roleCode");
        }
    }

    public void addRoleNameSelectProperty() {
        addRoleNameSelectProperty("roleName");
    }

    public void addRoleNameSelectProperty(String aAlias) {
        if (StringUtils.isNotBlank(aAlias)) {
            addSelectProperty(IProductRoleDefineDAO.RoleName, aAlias);
        } else {
            addSelectProperty(IProductRoleDefineDAO.RoleName, "roleName");
        }
    }

    public void addStatusSelectProperty() {
        addStatusSelectProperty("status");
    }

    public void addStatusSelectProperty(String aAlias) {
        if (StringUtils.isNotBlank(aAlias)) {
            addSelectProperty(IProductRoleDefineDAO.Status, aAlias);
        } else {
            addSelectProperty(IProductRoleDefineDAO.Status, "status");
        }
    }

    public void addRemarksSelectProperty() {
        addRemarksSelectProperty("remarks");
    }

    public void addRemarksSelectProperty(String aAlias) {
        if (StringUtils.isNotBlank(aAlias)) {
            addSelectProperty(IProductRoleDefineDAO.Remarks, aAlias);
        } else {
            addSelectProperty(IProductRoleDefineDAO.Remarks, "remarks");
        }
    }

    public void addProductDefineNameSelectProperty() {
        addProductDefineNameSelectProperty("productDefineName");
    }

    public void addProductDefineNameSelectProperty(String aAlias) {
        if (StringUtils.isNotBlank(aAlias)) {
            addSelectProperty(IProductRoleDefineDAO.ProductDefineName, aAlias);
        } else {
            addSelectProperty(IProductRoleDefineDAO.ProductDefineName,
                "productDefineName");
        }
    }

    public void addProductDefineStatusSelectProperty() {
        addProductDefineStatusSelectProperty("productDefineStatus");
    }

    public void addProductDefineStatusSelectProperty(String aAlias) {
        if (StringUtils.isNotBlank(aAlias)) {
            addSelectProperty(IProductRoleDefineDAO.ProductDefineStatus, aAlias);
        } else {
            addSelectProperty(IProductRoleDefineDAO.ProductDefineStatus,
                "productDefineStatus");
        }
    }

    public void addProductDefineCodeSelectProperty() {
        addProductDefineCodeSelectProperty("productDefineCode");
    }

    public void addProductDefineCodeSelectProperty(String aAlias) {
        if (StringUtils.isNotBlank(aAlias)) {
            addSelectProperty(IProductRoleDefineDAO.ProductDefineCode, aAlias);
        } else {
            addSelectProperty(IProductRoleDefineDAO.ProductDefineCode,
                "productDefineCode");
        }
    }

    public void addAllSelectProperties() {
        addIdSelectProperty();

        addProductDefineIdSelectProperty();

        addRoleCodeSelectProperty();

        addRoleNameSelectProperty();

        addStatusSelectProperty();

        addRemarksSelectProperty();

        addProductDefineNameSelectProperty();

        addProductDefineStatusSelectProperty();

        addProductDefineCodeSelectProperty();
    }

    public static class Criteria extends BaseWhereCriterion<ProductRoleDefineDAOQueryBean> {
        protected Criteria(ProductRoleDefineDAOQueryBean aParentObject) {
            super(aParentObject);
        }

        public Criteria andIdIsNull() {
            addCriterion(IProductRoleDefineDAO.Id + " is null");

            return this;
        }

        public Criteria andIdIsNotNull() {
            addCriterion(IProductRoleDefineDAO.Id + " is not null");

            return this;
        }

        public Criteria andIdIsNotEmpty() {
            addCriterion(IProductRoleDefineDAO.Id + " is not null AND " +
                IProductRoleDefineDAO.Id + " <> ''");

            return this;
        }

        public Criteria andIdIsEmpty() {
            addCriterion("(" + IProductRoleDefineDAO.Id + " is null OR " +
                IProductRoleDefineDAO.Id + " = '')");

            return this;
        }

        public Criteria andIdEqualTo(long value) {
            return andIdEqualTo(Long.valueOf(value));
        }

        public Criteria andIdEqualTo(java.lang.Long value) {
            addCriterion(IProductRoleDefineDAO.Id + " = ", value, "id");

            return this;
        }

        public Criteria andIdEqualToForeignKey(java.lang.String key) {
            StringBuffer str = new StringBuffer(IProductRoleDefineDAO.Id);
            str.append(" = ").append(key);
            addForeignKeyCriterion(str.toString());

            return this;
        }

        public Criteria andIdEqualTo(BaseQueryBean subQueryBean,
            IDataAccessInterface<?, ?> dao) {
            addCriterion(IProductRoleDefineDAO.Id + " = ", subQueryBean, dao);

            return this;
        }

        public Criteria andIdNotEqualTo(long value) {
            return andIdNotEqualTo(Long.valueOf(value));
        }

        public Criteria andIdNotEqualTo(java.lang.Long value) {
            addCriterion(IProductRoleDefineDAO.Id + " <>", value, "id");

            return this;
        }

        public Criteria andIdNotEqualToOrIsNull(long value) {
            return andIdNotEqualToOrIsNull(Long.valueOf(value));
        }

        public Criteria andIdNotEqualToOrIsNull(java.lang.Long value) {
            addCriterion(IProductRoleDefineDAO.Id + " is null OR " +
                IProductRoleDefineDAO.Id + " <>", value, "id");

            return this;
        }

        public Criteria andIdNotEqualToForeignKey(java.lang.String key) {
            StringBuffer str = new StringBuffer(IProductRoleDefineDAO.Id);
            str.append(" <> ").append(key);
            addForeignKeyCriterion(str.toString());

            return this;
        }

        public Criteria andIdNotEqualTo(BaseQueryBean subQueryBean,
            IDataAccessInterface<?, ?> dao) {
            addCriterion(IProductRoleDefineDAO.Id + " <> ", subQueryBean, dao);

            return this;
        }

        public Criteria andIdGreaterThan(long value) {
            return andIdGreaterThan(Long.valueOf(value));
        }

        public Criteria andIdGreaterThan(java.lang.Long value) {
            addCriterion(IProductRoleDefineDAO.Id + " >", value, "id");

            return this;
        }

        public Criteria andIdGreaterThanForeignKey(java.lang.String key) {
            StringBuffer str = new StringBuffer(IProductRoleDefineDAO.Id);
            str.append(" > ").append(key);
            addForeignKeyCriterion(str.toString());

            return this;
        }

        public Criteria andIdGreaterThan(BaseQueryBean subQueryBean,
            IDataAccessInterface<?, ?> dao) {
            addCriterion(IProductRoleDefineDAO.Id + " > ", subQueryBean, dao);

            return this;
        }

        public Criteria andIdGreaterThanOrEqualTo(long value) {
            return andIdGreaterThanOrEqualTo(Long.valueOf(value));
        }

        public Criteria andIdGreaterThanOrEqualTo(java.lang.Long value) {
            addCriterion(IProductRoleDefineDAO.Id + " >=", value, "id");

            return this;
        }

        public Criteria andIdGreaterThanOrEqualToForeignKey(
            java.lang.String key) {
            StringBuffer str = new StringBuffer(IProductRoleDefineDAO.Id);
            str.append(" >= ").append(key);
            addForeignKeyCriterion(str.toString());

            return this;
        }

        public Criteria andIdGreaterThanOrEqualTo(BaseQueryBean subQueryBean,
            IDataAccessInterface<?, ?> dao) {
            addCriterion(IProductRoleDefineDAO.Id + " >= ", subQueryBean, dao);

            return this;
        }

        public Criteria andIdLessThan(long value) {
            return andIdLessThan(Long.valueOf(value));
        }

        public Criteria andIdLessThan(java.lang.Long value) {
            addCriterion(IProductRoleDefineDAO.Id + " <", value, "id");

            return this;
        }

        public Criteria andIdLessThanForeignKey(java.lang.String key) {
            StringBuffer str = new StringBuffer(IProductRoleDefineDAO.Id);
            str.append(" < ").append(key);
            addForeignKeyCriterion(str.toString());

            return this;
        }

        public Criteria andIdLessThan(BaseQueryBean subQueryBean,
            IDataAccessInterface<?, ?> dao) {
            addCriterion(IProductRoleDefineDAO.Id + " < ", subQueryBean, dao);

            return this;
        }

        public Criteria andIdLessThanOrEqualTo(long value) {
            return andIdLessThanOrEqualTo(Long.valueOf(value));
        }

        public Criteria andIdLessThanOrEqualTo(java.lang.Long value) {
            addCriterion(IProductRoleDefineDAO.Id + " <=", value, "id");

            return this;
        }

        public Criteria andIdLessThanOrEqualToForeignKey(java.lang.String key) {
            StringBuffer str = new StringBuffer(IProductRoleDefineDAO.Id);
            str.append(" <= ").append(key);
            addForeignKeyCriterion(str.toString());

            return this;
        }

        public Criteria andIdLessThanOrEqualTo(BaseQueryBean subQueryBean,
            IDataAccessInterface<?, ?> dao) {
            addCriterion(IProductRoleDefineDAO.Id + " <= ", subQueryBean, dao);

            return this;
        }

        public Criteria andIdIn(long[] values) {
            if (values.length == 1) {
                return andIdEqualTo((java.lang.Long) values[0]);
            } else {
                addCriterion(IProductRoleDefineDAO.Id + " in", values, "id");

                return this;
            }
        }

        public Criteria andIdNotIn(long[] values) {
            if (values.length == 1) {
                return andIdNotEqualTo((java.lang.Long) values[0]);
            } else {
                addCriterion(IProductRoleDefineDAO.Id + " not in", values, "id");

                return this;
            }
        }

        public Criteria andIdIn(List<java.lang.Long> values) {
            if (values.size() == 1) {
                return andIdEqualTo(values.get(0));
            } else {
                addCriterion(IProductRoleDefineDAO.Id + " in", values, "id");

                return this;
            }
        }

        public Criteria andIdNotIn(List<java.lang.Long> values) {
            if (values.size() == 1) {
                return andIdNotEqualTo(values.get(0));
            } else {
                addCriterion(IProductRoleDefineDAO.Id + " not in", values, "id");

                return this;
            }
        }

        public Criteria andIdIn(java.lang.Long[] values) {
            if (values.length == 1) {
                return andIdEqualTo(values[0]);
            } else {
                addCriterion(IProductRoleDefineDAO.Id + " in",
                    Arrays.asList(values), "id");

                return this;
            }
        }

        public Criteria andIdNotIn(java.lang.Long[] values) {
            if (values.length == 1) {
                return andIdNotEqualTo(values[0]);
            } else {
                addCriterion(IProductRoleDefineDAO.Id + " not in",
                    Arrays.asList(values), "id");

                return this;
            }
        }

        public Criteria andIdIn(BaseQueryBean subQueryBean,
            IDataAccessInterface<?, ?> dao) {
            addCriterion(IProductRoleDefineDAO.Id + " in ", subQueryBean, dao);

            return this;
        }

        public Criteria andIdNotIn(BaseQueryBean subQueryBean,
            IDataAccessInterface<?, ?> dao) {
            addCriterion(IProductRoleDefineDAO.Id + " not in ", subQueryBean,
                dao);

            return this;
        }

        public Criteria andIdBetween(long value1, long value2) {
            addCriterion(IProductRoleDefineDAO.Id + " between", value1, value2,
                "id");

            return this;
        }

        public Criteria andIdBetween(java.lang.Long value1,
            java.lang.Long value2) {
            addCriterion(IProductRoleDefineDAO.Id + " between", value1, value2,
                "id");

            return this;
        }

        public Criteria andIdNotBetween(long value1, long value2) {
            addCriterion(IProductRoleDefineDAO.Id + " not between", value1,
                value2, "id");

            return this;
        }

        public Criteria andIdNotBetween(java.lang.Long value1,
            java.lang.Long value2) {
            addCriterion(IProductRoleDefineDAO.Id + " not between", value1,
                value2, "id");

            return this;
        }

        public Criteria andProductDefineIdIsNull() {
            addCriterion(IProductRoleDefineDAO.ProductDefineId + " is null");

            return this;
        }

        public Criteria andProductDefineIdIsNotNull() {
            addCriterion(IProductRoleDefineDAO.ProductDefineId +
                " is not null");

            return this;
        }

        public Criteria andProductDefineIdIsNotEmpty() {
            addCriterion(IProductRoleDefineDAO.ProductDefineId +
                " is not null AND " + IProductRoleDefineDAO.ProductDefineId +
                " <> ''");

            return this;
        }

        public Criteria andProductDefineIdIsEmpty() {
            addCriterion("(" + IProductRoleDefineDAO.ProductDefineId +
                " is null OR " + IProductRoleDefineDAO.ProductDefineId +
                " = '')");

            return this;
        }

        public Criteria andProductDefineIdEqualTo(long value) {
            return andProductDefineIdEqualTo(Long.valueOf(value));
        }

        public Criteria andProductDefineIdEqualTo(java.lang.Long value) {
            addCriterion(IProductRoleDefineDAO.ProductDefineId + " = ", value,
                "productDefineId");

            return this;
        }

        public Criteria andProductDefineIdEqualToForeignKey(
            java.lang.String key) {
            StringBuffer str = new StringBuffer(IProductRoleDefineDAO.ProductDefineId);
            str.append(" = ").append(key);
            addForeignKeyCriterion(str.toString());

            return this;
        }

        public Criteria andProductDefineIdEqualTo(BaseQueryBean subQueryBean,
            IDataAccessInterface<?, ?> dao) {
            addCriterion(IProductRoleDefineDAO.ProductDefineId + " = ",
                subQueryBean, dao);

            return this;
        }

        public Criteria andProductDefineIdNotEqualTo(long value) {
            return andProductDefineIdNotEqualTo(Long.valueOf(value));
        }

        public Criteria andProductDefineIdNotEqualTo(java.lang.Long value) {
            addCriterion(IProductRoleDefineDAO.ProductDefineId + " <>", value,
                "productDefineId");

            return this;
        }

        public Criteria andProductDefineIdNotEqualToOrIsNull(long value) {
            return andProductDefineIdNotEqualToOrIsNull(Long.valueOf(value));
        }

        public Criteria andProductDefineIdNotEqualToOrIsNull(
            java.lang.Long value) {
            addCriterion(IProductRoleDefineDAO.ProductDefineId +
                " is null OR " + IProductRoleDefineDAO.ProductDefineId + " <>",
                value, "productDefineId");

            return this;
        }

        public Criteria andProductDefineIdNotEqualToForeignKey(
            java.lang.String key) {
            StringBuffer str = new StringBuffer(IProductRoleDefineDAO.ProductDefineId);
            str.append(" <> ").append(key);
            addForeignKeyCriterion(str.toString());

            return this;
        }

        public Criteria andProductDefineIdNotEqualTo(
            BaseQueryBean subQueryBean, IDataAccessInterface<?, ?> dao) {
            addCriterion(IProductRoleDefineDAO.ProductDefineId + " <> ",
                subQueryBean, dao);

            return this;
        }

        public Criteria andProductDefineIdGreaterThan(long value) {
            return andProductDefineIdGreaterThan(Long.valueOf(value));
        }

        public Criteria andProductDefineIdGreaterThan(java.lang.Long value) {
            addCriterion(IProductRoleDefineDAO.ProductDefineId + " >", value,
                "productDefineId");

            return this;
        }

        public Criteria andProductDefineIdGreaterThanForeignKey(
            java.lang.String key) {
            StringBuffer str = new StringBuffer(IProductRoleDefineDAO.ProductDefineId);
            str.append(" > ").append(key);
            addForeignKeyCriterion(str.toString());

            return this;
        }

        public Criteria andProductDefineIdGreaterThan(
            BaseQueryBean subQueryBean, IDataAccessInterface<?, ?> dao) {
            addCriterion(IProductRoleDefineDAO.ProductDefineId + " > ",
                subQueryBean, dao);

            return this;
        }

        public Criteria andProductDefineIdGreaterThanOrEqualTo(long value) {
            return andProductDefineIdGreaterThanOrEqualTo(Long.valueOf(value));
        }

        public Criteria andProductDefineIdGreaterThanOrEqualTo(
            java.lang.Long value) {
            addCriterion(IProductRoleDefineDAO.ProductDefineId + " >=", value,
                "productDefineId");

            return this;
        }

        public Criteria andProductDefineIdGreaterThanOrEqualToForeignKey(
            java.lang.String key) {
            StringBuffer str = new StringBuffer(IProductRoleDefineDAO.ProductDefineId);
            str.append(" >= ").append(key);
            addForeignKeyCriterion(str.toString());

            return this;
        }

        public Criteria andProductDefineIdGreaterThanOrEqualTo(
            BaseQueryBean subQueryBean, IDataAccessInterface<?, ?> dao) {
            addCriterion(IProductRoleDefineDAO.ProductDefineId + " >= ",
                subQueryBean, dao);

            return this;
        }

        public Criteria andProductDefineIdLessThan(long value) {
            return andProductDefineIdLessThan(Long.valueOf(value));
        }

        public Criteria andProductDefineIdLessThan(java.lang.Long value) {
            addCriterion(IProductRoleDefineDAO.ProductDefineId + " <", value,
                "productDefineId");

            return this;
        }

        public Criteria andProductDefineIdLessThanForeignKey(
            java.lang.String key) {
            StringBuffer str = new StringBuffer(IProductRoleDefineDAO.ProductDefineId);
            str.append(" < ").append(key);
            addForeignKeyCriterion(str.toString());

            return this;
        }

        public Criteria andProductDefineIdLessThan(BaseQueryBean subQueryBean,
            IDataAccessInterface<?, ?> dao) {
            addCriterion(IProductRoleDefineDAO.ProductDefineId + " < ",
                subQueryBean, dao);

            return this;
        }

        public Criteria andProductDefineIdLessThanOrEqualTo(long value) {
            return andProductDefineIdLessThanOrEqualTo(Long.valueOf(value));
        }

        public Criteria andProductDefineIdLessThanOrEqualTo(
            java.lang.Long value) {
            addCriterion(IProductRoleDefineDAO.ProductDefineId + " <=", value,
                "productDefineId");

            return this;
        }

        public Criteria andProductDefineIdLessThanOrEqualToForeignKey(
            java.lang.String key) {
            StringBuffer str = new StringBuffer(IProductRoleDefineDAO.ProductDefineId);
            str.append(" <= ").append(key);
            addForeignKeyCriterion(str.toString());

            return this;
        }

        public Criteria andProductDefineIdLessThanOrEqualTo(
            BaseQueryBean subQueryBean, IDataAccessInterface<?, ?> dao) {
            addCriterion(IProductRoleDefineDAO.ProductDefineId + " <= ",
                subQueryBean, dao);

            return this;
        }

        public Criteria andProductDefineIdIn(long[] values) {
            if (values.length == 1) {
                return andProductDefineIdEqualTo((java.lang.Long) values[0]);
            } else {
                addCriterion(IProductRoleDefineDAO.ProductDefineId + " in",
                    values, "productDefineId");

                return this;
            }
        }

        public Criteria andProductDefineIdNotIn(long[] values) {
            if (values.length == 1) {
                return andProductDefineIdNotEqualTo((java.lang.Long) values[0]);
            } else {
                addCriterion(IProductRoleDefineDAO.ProductDefineId + " not in",
                    values, "productDefineId");

                return this;
            }
        }

        public Criteria andProductDefineIdIn(List<java.lang.Long> values) {
            if (values.size() == 1) {
                return andProductDefineIdEqualTo(values.get(0));
            } else {
                addCriterion(IProductRoleDefineDAO.ProductDefineId + " in",
                    values, "productDefineId");

                return this;
            }
        }

        public Criteria andProductDefineIdNotIn(List<java.lang.Long> values) {
            if (values.size() == 1) {
                return andProductDefineIdNotEqualTo(values.get(0));
            } else {
                addCriterion(IProductRoleDefineDAO.ProductDefineId + " not in",
                    values, "productDefineId");

                return this;
            }
        }

        public Criteria andProductDefineIdIn(java.lang.Long[] values) {
            if (values.length == 1) {
                return andProductDefineIdEqualTo(values[0]);
            } else {
                addCriterion(IProductRoleDefineDAO.ProductDefineId + " in",
                    Arrays.asList(values), "productDefineId");

                return this;
            }
        }

        public Criteria andProductDefineIdNotIn(java.lang.Long[] values) {
            if (values.length == 1) {
                return andProductDefineIdNotEqualTo(values[0]);
            } else {
                addCriterion(IProductRoleDefineDAO.ProductDefineId + " not in",
                    Arrays.asList(values), "productDefineId");

                return this;
            }
        }

        public Criteria andProductDefineIdIn(BaseQueryBean subQueryBean,
            IDataAccessInterface<?, ?> dao) {
            addCriterion(IProductRoleDefineDAO.ProductDefineId + " in ",
                subQueryBean, dao);

            return this;
        }

        public Criteria andProductDefineIdNotIn(BaseQueryBean subQueryBean,
            IDataAccessInterface<?, ?> dao) {
            addCriterion(IProductRoleDefineDAO.ProductDefineId + " not in ",
                subQueryBean, dao);

            return this;
        }

        public Criteria andProductDefineIdBetween(long value1, long value2) {
            addCriterion(IProductRoleDefineDAO.ProductDefineId + " between",
                value1, value2, "productDefineId");

            return this;
        }

        public Criteria andProductDefineIdBetween(java.lang.Long value1,
            java.lang.Long value2) {
            addCriterion(IProductRoleDefineDAO.ProductDefineId + " between",
                value1, value2, "productDefineId");

            return this;
        }

        public Criteria andProductDefineIdNotBetween(long value1, long value2) {
            addCriterion(IProductRoleDefineDAO.ProductDefineId +
                " not between", value1, value2, "productDefineId");

            return this;
        }

        public Criteria andProductDefineIdNotBetween(java.lang.Long value1,
            java.lang.Long value2) {
            addCriterion(IProductRoleDefineDAO.ProductDefineId +
                " not between", value1, value2, "productDefineId");

            return this;
        }

        public Criteria andRoleCodeIsNull() {
            addCriterion(IProductRoleDefineDAO.RoleCode + " is null");

            return this;
        }

        public Criteria andRoleCodeIsNotNull() {
            addCriterion(IProductRoleDefineDAO.RoleCode + " is not null");

            return this;
        }

        public Criteria andRoleCodeIsNotEmpty() {
            addCriterion(IProductRoleDefineDAO.RoleCode + " is not null AND " +
                IProductRoleDefineDAO.RoleCode + " <> ''");

            return this;
        }

        public Criteria andRoleCodeIsEmpty() {
            addCriterion("(" + IProductRoleDefineDAO.RoleCode + " is null OR " +
                IProductRoleDefineDAO.RoleCode + " = '')");

            return this;
        }

        public Criteria andRoleCodeEqualTo(String value) {
            addCriterion(IProductRoleDefineDAO.RoleCode + " = ", value,
                "roleCode");

            return this;
        }

        public Criteria andRoleCodeEqualToForeignKey(java.lang.String key) {
            StringBuffer str = new StringBuffer(IProductRoleDefineDAO.RoleCode);
            str.append(" = ").append(key);
            addForeignKeyCriterion(str.toString());

            return this;
        }

        public Criteria andRoleCodeEqualTo(BaseQueryBean subQueryBean,
            IDataAccessInterface<?, ?> dao) {
            addCriterion(IProductRoleDefineDAO.RoleCode + " = ", subQueryBean,
                dao);

            return this;
        }

        public Criteria andRoleCodeNotEqualTo(String value) {
            addCriterion(IProductRoleDefineDAO.RoleCode + " <>", value,
                "roleCode");

            return this;
        }

        public Criteria andRoleCodeNotEqualToOrIsNull(String value) {
            addCriterion(IProductRoleDefineDAO.RoleCode + " is null OR " +
                IProductRoleDefineDAO.RoleCode + " <>", value, "roleCode");

            return this;
        }

        public Criteria andRoleCodeNotEqualToForeignKey(java.lang.String key) {
            StringBuffer str = new StringBuffer(IProductRoleDefineDAO.RoleCode);
            str.append(" <> ").append(key);
            addForeignKeyCriterion(str.toString());

            return this;
        }

        public Criteria andRoleCodeNotEqualTo(BaseQueryBean subQueryBean,
            IDataAccessInterface<?, ?> dao) {
            addCriterion(IProductRoleDefineDAO.RoleCode + " <> ", subQueryBean,
                dao);

            return this;
        }

        public Criteria andRoleCodeGreaterThan(String value) {
            addCriterion(IProductRoleDefineDAO.RoleCode + " >", value,
                "roleCode");

            return this;
        }

        public Criteria andRoleCodeGreaterThanForeignKey(java.lang.String key) {
            StringBuffer str = new StringBuffer(IProductRoleDefineDAO.RoleCode);
            str.append(" > ").append(key);
            addForeignKeyCriterion(str.toString());

            return this;
        }

        public Criteria andRoleCodeGreaterThan(BaseQueryBean subQueryBean,
            IDataAccessInterface<?, ?> dao) {
            addCriterion(IProductRoleDefineDAO.RoleCode + " > ", subQueryBean,
                dao);

            return this;
        }

        public Criteria andRoleCodeGreaterThanOrEqualTo(String value) {
            addCriterion(IProductRoleDefineDAO.RoleCode + " >=", value,
                "roleCode");

            return this;
        }

        public Criteria andRoleCodeGreaterThanOrEqualToForeignKey(
            java.lang.String key) {
            StringBuffer str = new StringBuffer(IProductRoleDefineDAO.RoleCode);
            str.append(" >= ").append(key);
            addForeignKeyCriterion(str.toString());

            return this;
        }

        public Criteria andRoleCodeGreaterThanOrEqualTo(
            BaseQueryBean subQueryBean, IDataAccessInterface<?, ?> dao) {
            addCriterion(IProductRoleDefineDAO.RoleCode + " >= ", subQueryBean,
                dao);

            return this;
        }

        public Criteria andRoleCodeLessThan(String value) {
            addCriterion(IProductRoleDefineDAO.RoleCode + " <", value,
                "roleCode");

            return this;
        }

        public Criteria andRoleCodeLessThanForeignKey(java.lang.String key) {
            StringBuffer str = new StringBuffer(IProductRoleDefineDAO.RoleCode);
            str.append(" < ").append(key);
            addForeignKeyCriterion(str.toString());

            return this;
        }

        public Criteria andRoleCodeLessThan(BaseQueryBean subQueryBean,
            IDataAccessInterface<?, ?> dao) {
            addCriterion(IProductRoleDefineDAO.RoleCode + " < ", subQueryBean,
                dao);

            return this;
        }

        public Criteria andRoleCodeLessThanOrEqualTo(String value) {
            addCriterion(IProductRoleDefineDAO.RoleCode + " <=", value,
                "roleCode");

            return this;
        }

        public Criteria andRoleCodeLessThanOrEqualToForeignKey(
            java.lang.String key) {
            StringBuffer str = new StringBuffer(IProductRoleDefineDAO.RoleCode);
            str.append(" <= ").append(key);
            addForeignKeyCriterion(str.toString());

            return this;
        }

        public Criteria andRoleCodeLessThanOrEqualTo(
            BaseQueryBean subQueryBean, IDataAccessInterface<?, ?> dao) {
            addCriterion(IProductRoleDefineDAO.RoleCode + " <= ", subQueryBean,
                dao);

            return this;
        }

        public Criteria andRoleCodeLike(String value) {
            StringBuffer buffer = new StringBuffer("%");
            buffer.append(value);
            buffer.append("%");
            addCriterion(IProductRoleDefineDAO.RoleCode + " like",
                buffer.toString(), "roleCode");

            return this;
        }

        public Criteria andRoleCodeNotLike(String value) {
            StringBuffer buffer = new StringBuffer("%");
            buffer.append(value);
            buffer.append("%");
            addCriterion(IProductRoleDefineDAO.RoleCode + " not like",
                buffer.toString(), "roleCode");

            return this;
        }

        public Criteria andRoleCodeIn(List<String> values) {
            if (values.size() == 1) {
                return andRoleCodeEqualTo(values.get(0));
            } else {
                addCriterion(IProductRoleDefineDAO.RoleCode + " in", values,
                    "roleCode");

                return this;
            }
        }

        public Criteria andRoleCodeNotIn(List<String> values) {
            if (values.size() == 1) {
                return andRoleCodeNotEqualTo(values.get(0));
            } else {
                addCriterion(IProductRoleDefineDAO.RoleCode + " not in",
                    values, "roleCode");

                return this;
            }
        }

        public Criteria andRoleCodeIn(String[] values) {
            if (values.length == 1) {
                return andRoleCodeEqualTo(values[0]);
            } else {
                addCriterion(IProductRoleDefineDAO.RoleCode + " in",
                    Arrays.asList(values), "roleCode");

                return this;
            }
        }

        public Criteria andRoleCodeNotIn(String[] values) {
            if (values.length == 1) {
                return andRoleCodeNotEqualTo(values[0]);
            } else {
                addCriterion(IProductRoleDefineDAO.RoleCode + " not in",
                    Arrays.asList(values), "roleCode");

                return this;
            }
        }

        public Criteria andRoleCodeIn(BaseQueryBean subQueryBean,
            IDataAccessInterface<?, ?> dao) {
            addCriterion(IProductRoleDefineDAO.RoleCode + " in ", subQueryBean,
                dao);

            return this;
        }

        public Criteria andRoleCodeNotIn(BaseQueryBean subQueryBean,
            IDataAccessInterface<?, ?> dao) {
            addCriterion(IProductRoleDefineDAO.RoleCode + " not in ",
                subQueryBean, dao);

            return this;
        }

        public Criteria andRoleCodeBetween(String value1, String value2) {
            addCriterion(IProductRoleDefineDAO.RoleCode + " between", value1,
                value2, "roleCode");

            return this;
        }

        public Criteria andRoleCodeNotBetween(String value1, String value2) {
            addCriterion(IProductRoleDefineDAO.RoleCode + " not between",
                value1, value2, "roleCode");

            return this;
        }

        public Criteria andRoleNameIsNull() {
            addCriterion(IProductRoleDefineDAO.RoleName + " is null");

            return this;
        }

        public Criteria andRoleNameIsNotNull() {
            addCriterion(IProductRoleDefineDAO.RoleName + " is not null");

            return this;
        }

        public Criteria andRoleNameIsNotEmpty() {
            addCriterion(IProductRoleDefineDAO.RoleName + " is not null AND " +
                IProductRoleDefineDAO.RoleName + " <> ''");

            return this;
        }

        public Criteria andRoleNameIsEmpty() {
            addCriterion("(" + IProductRoleDefineDAO.RoleName + " is null OR " +
                IProductRoleDefineDAO.RoleName + " = '')");

            return this;
        }

        public Criteria andRoleNameEqualTo(String value) {
            addCriterion(IProductRoleDefineDAO.RoleName + " = ", value,
                "roleName");

            return this;
        }

        public Criteria andRoleNameEqualToForeignKey(java.lang.String key) {
            StringBuffer str = new StringBuffer(IProductRoleDefineDAO.RoleName);
            str.append(" = ").append(key);
            addForeignKeyCriterion(str.toString());

            return this;
        }

        public Criteria andRoleNameEqualTo(BaseQueryBean subQueryBean,
            IDataAccessInterface<?, ?> dao) {
            addCriterion(IProductRoleDefineDAO.RoleName + " = ", subQueryBean,
                dao);

            return this;
        }

        public Criteria andRoleNameNotEqualTo(String value) {
            addCriterion(IProductRoleDefineDAO.RoleName + " <>", value,
                "roleName");

            return this;
        }

        public Criteria andRoleNameNotEqualToOrIsNull(String value) {
            addCriterion(IProductRoleDefineDAO.RoleName + " is null OR " +
                IProductRoleDefineDAO.RoleName + " <>", value, "roleName");

            return this;
        }

        public Criteria andRoleNameNotEqualToForeignKey(java.lang.String key) {
            StringBuffer str = new StringBuffer(IProductRoleDefineDAO.RoleName);
            str.append(" <> ").append(key);
            addForeignKeyCriterion(str.toString());

            return this;
        }

        public Criteria andRoleNameNotEqualTo(BaseQueryBean subQueryBean,
            IDataAccessInterface<?, ?> dao) {
            addCriterion(IProductRoleDefineDAO.RoleName + " <> ", subQueryBean,
                dao);

            return this;
        }

        public Criteria andRoleNameGreaterThan(String value) {
            addCriterion(IProductRoleDefineDAO.RoleName + " >", value,
                "roleName");

            return this;
        }

        public Criteria andRoleNameGreaterThanForeignKey(java.lang.String key) {
            StringBuffer str = new StringBuffer(IProductRoleDefineDAO.RoleName);
            str.append(" > ").append(key);
            addForeignKeyCriterion(str.toString());

            return this;
        }

        public Criteria andRoleNameGreaterThan(BaseQueryBean subQueryBean,
            IDataAccessInterface<?, ?> dao) {
            addCriterion(IProductRoleDefineDAO.RoleName + " > ", subQueryBean,
                dao);

            return this;
        }

        public Criteria andRoleNameGreaterThanOrEqualTo(String value) {
            addCriterion(IProductRoleDefineDAO.RoleName + " >=", value,
                "roleName");

            return this;
        }

        public Criteria andRoleNameGreaterThanOrEqualToForeignKey(
            java.lang.String key) {
            StringBuffer str = new StringBuffer(IProductRoleDefineDAO.RoleName);
            str.append(" >= ").append(key);
            addForeignKeyCriterion(str.toString());

            return this;
        }

        public Criteria andRoleNameGreaterThanOrEqualTo(
            BaseQueryBean subQueryBean, IDataAccessInterface<?, ?> dao) {
            addCriterion(IProductRoleDefineDAO.RoleName + " >= ", subQueryBean,
                dao);

            return this;
        }

        public Criteria andRoleNameLessThan(String value) {
            addCriterion(IProductRoleDefineDAO.RoleName + " <", value,
                "roleName");

            return this;
        }

        public Criteria andRoleNameLessThanForeignKey(java.lang.String key) {
            StringBuffer str = new StringBuffer(IProductRoleDefineDAO.RoleName);
            str.append(" < ").append(key);
            addForeignKeyCriterion(str.toString());

            return this;
        }

        public Criteria andRoleNameLessThan(BaseQueryBean subQueryBean,
            IDataAccessInterface<?, ?> dao) {
            addCriterion(IProductRoleDefineDAO.RoleName + " < ", subQueryBean,
                dao);

            return this;
        }

        public Criteria andRoleNameLessThanOrEqualTo(String value) {
            addCriterion(IProductRoleDefineDAO.RoleName + " <=", value,
                "roleName");

            return this;
        }

        public Criteria andRoleNameLessThanOrEqualToForeignKey(
            java.lang.String key) {
            StringBuffer str = new StringBuffer(IProductRoleDefineDAO.RoleName);
            str.append(" <= ").append(key);
            addForeignKeyCriterion(str.toString());

            return this;
        }

        public Criteria andRoleNameLessThanOrEqualTo(
            BaseQueryBean subQueryBean, IDataAccessInterface<?, ?> dao) {
            addCriterion(IProductRoleDefineDAO.RoleName + " <= ", subQueryBean,
                dao);

            return this;
        }

        public Criteria andRoleNameLike(String value) {
            StringBuffer buffer = new StringBuffer("%");
            buffer.append(value);
            buffer.append("%");
            addCriterion(IProductRoleDefineDAO.RoleName + " like",
                buffer.toString(), "roleName");

            return this;
        }

        public Criteria andRoleNameNotLike(String value) {
            StringBuffer buffer = new StringBuffer("%");
            buffer.append(value);
            buffer.append("%");
            addCriterion(IProductRoleDefineDAO.RoleName + " not like",
                buffer.toString(), "roleName");

            return this;
        }

        public Criteria andRoleNameIn(List<String> values) {
            if (values.size() == 1) {
                return andRoleNameEqualTo(values.get(0));
            } else {
                addCriterion(IProductRoleDefineDAO.RoleName + " in", values,
                    "roleName");

                return this;
            }
        }

        public Criteria andRoleNameNotIn(List<String> values) {
            if (values.size() == 1) {
                return andRoleNameNotEqualTo(values.get(0));
            } else {
                addCriterion(IProductRoleDefineDAO.RoleName + " not in",
                    values, "roleName");

                return this;
            }
        }

        public Criteria andRoleNameIn(String[] values) {
            if (values.length == 1) {
                return andRoleNameEqualTo(values[0]);
            } else {
                addCriterion(IProductRoleDefineDAO.RoleName + " in",
                    Arrays.asList(values), "roleName");

                return this;
            }
        }

        public Criteria andRoleNameNotIn(String[] values) {
            if (values.length == 1) {
                return andRoleNameNotEqualTo(values[0]);
            } else {
                addCriterion(IProductRoleDefineDAO.RoleName + " not in",
                    Arrays.asList(values), "roleName");

                return this;
            }
        }

        public Criteria andRoleNameIn(BaseQueryBean subQueryBean,
            IDataAccessInterface<?, ?> dao) {
            addCriterion(IProductRoleDefineDAO.RoleName + " in ", subQueryBean,
                dao);

            return this;
        }

        public Criteria andRoleNameNotIn(BaseQueryBean subQueryBean,
            IDataAccessInterface<?, ?> dao) {
            addCriterion(IProductRoleDefineDAO.RoleName + " not in ",
                subQueryBean, dao);

            return this;
        }

        public Criteria andRoleNameBetween(String value1, String value2) {
            addCriterion(IProductRoleDefineDAO.RoleName + " between", value1,
                value2, "roleName");

            return this;
        }

        public Criteria andRoleNameNotBetween(String value1, String value2) {
            addCriterion(IProductRoleDefineDAO.RoleName + " not between",
                value1, value2, "roleName");

            return this;
        }

        public Criteria andStatusIsNull() {
            addCriterion(IProductRoleDefineDAO.Status + " is null");

            return this;
        }

        public Criteria andStatusIsNotNull() {
            addCriterion(IProductRoleDefineDAO.Status + " is not null");

            return this;
        }

        public Criteria andStatusIsNotEmpty() {
            addCriterion(IProductRoleDefineDAO.Status + " is not null AND " +
                IProductRoleDefineDAO.Status + " <> ''");

            return this;
        }

        public Criteria andStatusIsEmpty() {
            addCriterion("(" + IProductRoleDefineDAO.Status + " is null OR " +
                IProductRoleDefineDAO.Status + " = '')");

            return this;
        }

        public Criteria andStatusEqualTo(String value) {
            addCriterion(IProductRoleDefineDAO.Status + " = ", value, "status");

            return this;
        }

        public Criteria andStatusEqualToForeignKey(java.lang.String key) {
            StringBuffer str = new StringBuffer(IProductRoleDefineDAO.Status);
            str.append(" = ").append(key);
            addForeignKeyCriterion(str.toString());

            return this;
        }

        public Criteria andStatusEqualTo(BaseQueryBean subQueryBean,
            IDataAccessInterface<?, ?> dao) {
            addCriterion(IProductRoleDefineDAO.Status + " = ", subQueryBean, dao);

            return this;
        }

        public Criteria andStatusNotEqualTo(String value) {
            addCriterion(IProductRoleDefineDAO.Status + " <>", value, "status");

            return this;
        }

        public Criteria andStatusNotEqualToOrIsNull(String value) {
            addCriterion(IProductRoleDefineDAO.Status + " is null OR " +
                IProductRoleDefineDAO.Status + " <>", value, "status");

            return this;
        }

        public Criteria andStatusNotEqualToForeignKey(java.lang.String key) {
            StringBuffer str = new StringBuffer(IProductRoleDefineDAO.Status);
            str.append(" <> ").append(key);
            addForeignKeyCriterion(str.toString());

            return this;
        }

        public Criteria andStatusNotEqualTo(BaseQueryBean subQueryBean,
            IDataAccessInterface<?, ?> dao) {
            addCriterion(IProductRoleDefineDAO.Status + " <> ", subQueryBean,
                dao);

            return this;
        }

        public Criteria andStatusGreaterThan(String value) {
            addCriterion(IProductRoleDefineDAO.Status + " >", value, "status");

            return this;
        }

        public Criteria andStatusGreaterThanForeignKey(java.lang.String key) {
            StringBuffer str = new StringBuffer(IProductRoleDefineDAO.Status);
            str.append(" > ").append(key);
            addForeignKeyCriterion(str.toString());

            return this;
        }

        public Criteria andStatusGreaterThan(BaseQueryBean subQueryBean,
            IDataAccessInterface<?, ?> dao) {
            addCriterion(IProductRoleDefineDAO.Status + " > ", subQueryBean, dao);

            return this;
        }

        public Criteria andStatusGreaterThanOrEqualTo(String value) {
            addCriterion(IProductRoleDefineDAO.Status + " >=", value, "status");

            return this;
        }

        public Criteria andStatusGreaterThanOrEqualToForeignKey(
            java.lang.String key) {
            StringBuffer str = new StringBuffer(IProductRoleDefineDAO.Status);
            str.append(" >= ").append(key);
            addForeignKeyCriterion(str.toString());

            return this;
        }

        public Criteria andStatusGreaterThanOrEqualTo(
            BaseQueryBean subQueryBean, IDataAccessInterface<?, ?> dao) {
            addCriterion(IProductRoleDefineDAO.Status + " >= ", subQueryBean,
                dao);

            return this;
        }

        public Criteria andStatusLessThan(String value) {
            addCriterion(IProductRoleDefineDAO.Status + " <", value, "status");

            return this;
        }

        public Criteria andStatusLessThanForeignKey(java.lang.String key) {
            StringBuffer str = new StringBuffer(IProductRoleDefineDAO.Status);
            str.append(" < ").append(key);
            addForeignKeyCriterion(str.toString());

            return this;
        }

        public Criteria andStatusLessThan(BaseQueryBean subQueryBean,
            IDataAccessInterface<?, ?> dao) {
            addCriterion(IProductRoleDefineDAO.Status + " < ", subQueryBean, dao);

            return this;
        }

        public Criteria andStatusLessThanOrEqualTo(String value) {
            addCriterion(IProductRoleDefineDAO.Status + " <=", value, "status");

            return this;
        }

        public Criteria andStatusLessThanOrEqualToForeignKey(
            java.lang.String key) {
            StringBuffer str = new StringBuffer(IProductRoleDefineDAO.Status);
            str.append(" <= ").append(key);
            addForeignKeyCriterion(str.toString());

            return this;
        }

        public Criteria andStatusLessThanOrEqualTo(BaseQueryBean subQueryBean,
            IDataAccessInterface<?, ?> dao) {
            addCriterion(IProductRoleDefineDAO.Status + " <= ", subQueryBean,
                dao);

            return this;
        }

        public Criteria andStatusLike(String value) {
            StringBuffer buffer = new StringBuffer("%");
            buffer.append(value);
            buffer.append("%");
            addCriterion(IProductRoleDefineDAO.Status + " like",
                buffer.toString(), "status");

            return this;
        }

        public Criteria andStatusNotLike(String value) {
            StringBuffer buffer = new StringBuffer("%");
            buffer.append(value);
            buffer.append("%");
            addCriterion(IProductRoleDefineDAO.Status + " not like",
                buffer.toString(), "status");

            return this;
        }

        public Criteria andStatusIn(List<String> values) {
            if (values.size() == 1) {
                return andStatusEqualTo(values.get(0));
            } else {
                addCriterion(IProductRoleDefineDAO.Status + " in", values,
                    "status");

                return this;
            }
        }

        public Criteria andStatusNotIn(List<String> values) {
            if (values.size() == 1) {
                return andStatusNotEqualTo(values.get(0));
            } else {
                addCriterion(IProductRoleDefineDAO.Status + " not in", values,
                    "status");

                return this;
            }
        }

        public Criteria andStatusIn(String[] values) {
            if (values.length == 1) {
                return andStatusEqualTo(values[0]);
            } else {
                addCriterion(IProductRoleDefineDAO.Status + " in",
                    Arrays.asList(values), "status");

                return this;
            }
        }

        public Criteria andStatusNotIn(String[] values) {
            if (values.length == 1) {
                return andStatusNotEqualTo(values[0]);
            } else {
                addCriterion(IProductRoleDefineDAO.Status + " not in",
                    Arrays.asList(values), "status");

                return this;
            }
        }

        public Criteria andStatusIn(BaseQueryBean subQueryBean,
            IDataAccessInterface<?, ?> dao) {
            addCriterion(IProductRoleDefineDAO.Status + " in ", subQueryBean,
                dao);

            return this;
        }

        public Criteria andStatusNotIn(BaseQueryBean subQueryBean,
            IDataAccessInterface<?, ?> dao) {
            addCriterion(IProductRoleDefineDAO.Status + " not in ",
                subQueryBean, dao);

            return this;
        }

        public Criteria andStatusBetween(String value1, String value2) {
            addCriterion(IProductRoleDefineDAO.Status + " between", value1,
                value2, "status");

            return this;
        }

        public Criteria andStatusNotBetween(String value1, String value2) {
            addCriterion(IProductRoleDefineDAO.Status + " not between", value1,
                value2, "status");

            return this;
        }

        public Criteria andRemarksIsNull() {
            addCriterion(IProductRoleDefineDAO.Remarks + " is null");

            return this;
        }

        public Criteria andRemarksIsNotNull() {
            addCriterion(IProductRoleDefineDAO.Remarks + " is not null");

            return this;
        }

        public Criteria andRemarksIsNotEmpty() {
            addCriterion(IProductRoleDefineDAO.Remarks + " is not null AND " +
                IProductRoleDefineDAO.Remarks + " <> ''");

            return this;
        }

        public Criteria andRemarksIsEmpty() {
            addCriterion("(" + IProductRoleDefineDAO.Remarks + " is null OR " +
                IProductRoleDefineDAO.Remarks + " = '')");

            return this;
        }

        public Criteria andRemarksEqualTo(String value) {
            addCriterion(IProductRoleDefineDAO.Remarks + " = ", value, "remarks");

            return this;
        }

        public Criteria andRemarksEqualToForeignKey(java.lang.String key) {
            StringBuffer str = new StringBuffer(IProductRoleDefineDAO.Remarks);
            str.append(" = ").append(key);
            addForeignKeyCriterion(str.toString());

            return this;
        }

        public Criteria andRemarksEqualTo(BaseQueryBean subQueryBean,
            IDataAccessInterface<?, ?> dao) {
            addCriterion(IProductRoleDefineDAO.Remarks + " = ", subQueryBean,
                dao);

            return this;
        }

        public Criteria andRemarksNotEqualTo(String value) {
            addCriterion(IProductRoleDefineDAO.Remarks + " <>", value, "remarks");

            return this;
        }

        public Criteria andRemarksNotEqualToOrIsNull(String value) {
            addCriterion(IProductRoleDefineDAO.Remarks + " is null OR " +
                IProductRoleDefineDAO.Remarks + " <>", value, "remarks");

            return this;
        }

        public Criteria andRemarksNotEqualToForeignKey(java.lang.String key) {
            StringBuffer str = new StringBuffer(IProductRoleDefineDAO.Remarks);
            str.append(" <> ").append(key);
            addForeignKeyCriterion(str.toString());

            return this;
        }

        public Criteria andRemarksNotEqualTo(BaseQueryBean subQueryBean,
            IDataAccessInterface<?, ?> dao) {
            addCriterion(IProductRoleDefineDAO.Remarks + " <> ", subQueryBean,
                dao);

            return this;
        }

        public Criteria andRemarksGreaterThan(String value) {
            addCriterion(IProductRoleDefineDAO.Remarks + " >", value, "remarks");

            return this;
        }

        public Criteria andRemarksGreaterThanForeignKey(java.lang.String key) {
            StringBuffer str = new StringBuffer(IProductRoleDefineDAO.Remarks);
            str.append(" > ").append(key);
            addForeignKeyCriterion(str.toString());

            return this;
        }

        public Criteria andRemarksGreaterThan(BaseQueryBean subQueryBean,
            IDataAccessInterface<?, ?> dao) {
            addCriterion(IProductRoleDefineDAO.Remarks + " > ", subQueryBean,
                dao);

            return this;
        }

        public Criteria andRemarksGreaterThanOrEqualTo(String value) {
            addCriterion(IProductRoleDefineDAO.Remarks + " >=", value, "remarks");

            return this;
        }

        public Criteria andRemarksGreaterThanOrEqualToForeignKey(
            java.lang.String key) {
            StringBuffer str = new StringBuffer(IProductRoleDefineDAO.Remarks);
            str.append(" >= ").append(key);
            addForeignKeyCriterion(str.toString());

            return this;
        }

        public Criteria andRemarksGreaterThanOrEqualTo(
            BaseQueryBean subQueryBean, IDataAccessInterface<?, ?> dao) {
            addCriterion(IProductRoleDefineDAO.Remarks + " >= ", subQueryBean,
                dao);

            return this;
        }

        public Criteria andRemarksLessThan(String value) {
            addCriterion(IProductRoleDefineDAO.Remarks + " <", value, "remarks");

            return this;
        }

        public Criteria andRemarksLessThanForeignKey(java.lang.String key) {
            StringBuffer str = new StringBuffer(IProductRoleDefineDAO.Remarks);
            str.append(" < ").append(key);
            addForeignKeyCriterion(str.toString());

            return this;
        }

        public Criteria andRemarksLessThan(BaseQueryBean subQueryBean,
            IDataAccessInterface<?, ?> dao) {
            addCriterion(IProductRoleDefineDAO.Remarks + " < ", subQueryBean,
                dao);

            return this;
        }

        public Criteria andRemarksLessThanOrEqualTo(String value) {
            addCriterion(IProductRoleDefineDAO.Remarks + " <=", value, "remarks");

            return this;
        }

        public Criteria andRemarksLessThanOrEqualToForeignKey(
            java.lang.String key) {
            StringBuffer str = new StringBuffer(IProductRoleDefineDAO.Remarks);
            str.append(" <= ").append(key);
            addForeignKeyCriterion(str.toString());

            return this;
        }

        public Criteria andRemarksLessThanOrEqualTo(
            BaseQueryBean subQueryBean, IDataAccessInterface<?, ?> dao) {
            addCriterion(IProductRoleDefineDAO.Remarks + " <= ", subQueryBean,
                dao);

            return this;
        }

        public Criteria andRemarksLike(String value) {
            StringBuffer buffer = new StringBuffer("%");
            buffer.append(value);
            buffer.append("%");
            addCriterion(IProductRoleDefineDAO.Remarks + " like",
                buffer.toString(), "remarks");

            return this;
        }

        public Criteria andRemarksNotLike(String value) {
            StringBuffer buffer = new StringBuffer("%");
            buffer.append(value);
            buffer.append("%");
            addCriterion(IProductRoleDefineDAO.Remarks + " not like",
                buffer.toString(), "remarks");

            return this;
        }

        public Criteria andRemarksIn(List<String> values) {
            if (values.size() == 1) {
                return andRemarksEqualTo(values.get(0));
            } else {
                addCriterion(IProductRoleDefineDAO.Remarks + " in", values,
                    "remarks");

                return this;
            }
        }

        public Criteria andRemarksNotIn(List<String> values) {
            if (values.size() == 1) {
                return andRemarksNotEqualTo(values.get(0));
            } else {
                addCriterion(IProductRoleDefineDAO.Remarks + " not in", values,
                    "remarks");

                return this;
            }
        }

        public Criteria andRemarksIn(String[] values) {
            if (values.length == 1) {
                return andRemarksEqualTo(values[0]);
            } else {
                addCriterion(IProductRoleDefineDAO.Remarks + " in",
                    Arrays.asList(values), "remarks");

                return this;
            }
        }

        public Criteria andRemarksNotIn(String[] values) {
            if (values.length == 1) {
                return andRemarksNotEqualTo(values[0]);
            } else {
                addCriterion(IProductRoleDefineDAO.Remarks + " not in",
                    Arrays.asList(values), "remarks");

                return this;
            }
        }

        public Criteria andRemarksIn(BaseQueryBean subQueryBean,
            IDataAccessInterface<?, ?> dao) {
            addCriterion(IProductRoleDefineDAO.Remarks + " in ", subQueryBean,
                dao);

            return this;
        }

        public Criteria andRemarksNotIn(BaseQueryBean subQueryBean,
            IDataAccessInterface<?, ?> dao) {
            addCriterion(IProductRoleDefineDAO.Remarks + " not in ",
                subQueryBean, dao);

            return this;
        }

        public Criteria andRemarksBetween(String value1, String value2) {
            addCriterion(IProductRoleDefineDAO.Remarks + " between", value1,
                value2, "remarks");

            return this;
        }

        public Criteria andRemarksNotBetween(String value1, String value2) {
            addCriterion(IProductRoleDefineDAO.Remarks + " not between",
                value1, value2, "remarks");

            return this;
        }

        public Criteria andProductDefineNameIsNull() {
            addCriterion(IProductRoleDefineDAO.ProductDefineName + " is null");

            return this;
        }

        public Criteria andProductDefineNameIsNotNull() {
            addCriterion(IProductRoleDefineDAO.ProductDefineName +
                " is not null");

            return this;
        }

        public Criteria andProductDefineNameIsNotEmpty() {
            addCriterion(IProductRoleDefineDAO.ProductDefineName +
                " is not null AND " + IProductRoleDefineDAO.ProductDefineName +
                " <> ''");

            return this;
        }

        public Criteria andProductDefineNameIsEmpty() {
            addCriterion("(" + IProductRoleDefineDAO.ProductDefineName +
                " is null OR " + IProductRoleDefineDAO.ProductDefineName +
                " = '')");

            return this;
        }

        public Criteria andProductDefineNameEqualTo(String value) {
            addCriterion(IProductRoleDefineDAO.ProductDefineName + " = ",
                value, "productDefineName");

            return this;
        }

        public Criteria andProductDefineNameEqualToForeignKey(
            java.lang.String key) {
            StringBuffer str = new StringBuffer(IProductRoleDefineDAO.ProductDefineName);
            str.append(" = ").append(key);
            addForeignKeyCriterion(str.toString());

            return this;
        }

        public Criteria andProductDefineNameEqualTo(
            BaseQueryBean subQueryBean, IDataAccessInterface<?, ?> dao) {
            addCriterion(IProductRoleDefineDAO.ProductDefineName + " = ",
                subQueryBean, dao);

            return this;
        }

        public Criteria andProductDefineNameNotEqualTo(String value) {
            addCriterion(IProductRoleDefineDAO.ProductDefineName + " <>",
                value, "productDefineName");

            return this;
        }

        public Criteria andProductDefineNameNotEqualToOrIsNull(String value) {
            addCriterion(IProductRoleDefineDAO.ProductDefineName +
                " is null OR " + IProductRoleDefineDAO.ProductDefineName +
                " <>", value, "productDefineName");

            return this;
        }

        public Criteria andProductDefineNameNotEqualToForeignKey(
            java.lang.String key) {
            StringBuffer str = new StringBuffer(IProductRoleDefineDAO.ProductDefineName);
            str.append(" <> ").append(key);
            addForeignKeyCriterion(str.toString());

            return this;
        }

        public Criteria andProductDefineNameNotEqualTo(
            BaseQueryBean subQueryBean, IDataAccessInterface<?, ?> dao) {
            addCriterion(IProductRoleDefineDAO.ProductDefineName + " <> ",
                subQueryBean, dao);

            return this;
        }

        public Criteria andProductDefineNameGreaterThan(String value) {
            addCriterion(IProductRoleDefineDAO.ProductDefineName + " >", value,
                "productDefineName");

            return this;
        }

        public Criteria andProductDefineNameGreaterThanForeignKey(
            java.lang.String key) {
            StringBuffer str = new StringBuffer(IProductRoleDefineDAO.ProductDefineName);
            str.append(" > ").append(key);
            addForeignKeyCriterion(str.toString());

            return this;
        }

        public Criteria andProductDefineNameGreaterThan(
            BaseQueryBean subQueryBean, IDataAccessInterface<?, ?> dao) {
            addCriterion(IProductRoleDefineDAO.ProductDefineName + " > ",
                subQueryBean, dao);

            return this;
        }

        public Criteria andProductDefineNameGreaterThanOrEqualTo(String value) {
            addCriterion(IProductRoleDefineDAO.ProductDefineName + " >=",
                value, "productDefineName");

            return this;
        }

        public Criteria andProductDefineNameGreaterThanOrEqualToForeignKey(
            java.lang.String key) {
            StringBuffer str = new StringBuffer(IProductRoleDefineDAO.ProductDefineName);
            str.append(" >= ").append(key);
            addForeignKeyCriterion(str.toString());

            return this;
        }

        public Criteria andProductDefineNameGreaterThanOrEqualTo(
            BaseQueryBean subQueryBean, IDataAccessInterface<?, ?> dao) {
            addCriterion(IProductRoleDefineDAO.ProductDefineName + " >= ",
                subQueryBean, dao);

            return this;
        }

        public Criteria andProductDefineNameLessThan(String value) {
            addCriterion(IProductRoleDefineDAO.ProductDefineName + " <", value,
                "productDefineName");

            return this;
        }

        public Criteria andProductDefineNameLessThanForeignKey(
            java.lang.String key) {
            StringBuffer str = new StringBuffer(IProductRoleDefineDAO.ProductDefineName);
            str.append(" < ").append(key);
            addForeignKeyCriterion(str.toString());

            return this;
        }

        public Criteria andProductDefineNameLessThan(
            BaseQueryBean subQueryBean, IDataAccessInterface<?, ?> dao) {
            addCriterion(IProductRoleDefineDAO.ProductDefineName + " < ",
                subQueryBean, dao);

            return this;
        }

        public Criteria andProductDefineNameLessThanOrEqualTo(String value) {
            addCriterion(IProductRoleDefineDAO.ProductDefineName + " <=",
                value, "productDefineName");

            return this;
        }

        public Criteria andProductDefineNameLessThanOrEqualToForeignKey(
            java.lang.String key) {
            StringBuffer str = new StringBuffer(IProductRoleDefineDAO.ProductDefineName);
            str.append(" <= ").append(key);
            addForeignKeyCriterion(str.toString());

            return this;
        }

        public Criteria andProductDefineNameLessThanOrEqualTo(
            BaseQueryBean subQueryBean, IDataAccessInterface<?, ?> dao) {
            addCriterion(IProductRoleDefineDAO.ProductDefineName + " <= ",
                subQueryBean, dao);

            return this;
        }

        public Criteria andProductDefineNameLike(String value) {
            StringBuffer buffer = new StringBuffer("%");
            buffer.append(value);
            buffer.append("%");
            addCriterion(IProductRoleDefineDAO.ProductDefineName + " like",
                buffer.toString(), "productDefineName");

            return this;
        }

        public Criteria andProductDefineNameNotLike(String value) {
            StringBuffer buffer = new StringBuffer("%");
            buffer.append(value);
            buffer.append("%");
            addCriterion(IProductRoleDefineDAO.ProductDefineName + " not like",
                buffer.toString(), "productDefineName");

            return this;
        }

        public Criteria andProductDefineNameIn(List<String> values) {
            if (values.size() == 1) {
                return andProductDefineNameEqualTo(values.get(0));
            } else {
                addCriterion(IProductRoleDefineDAO.ProductDefineName + " in",
                    values, "productDefineName");

                return this;
            }
        }

        public Criteria andProductDefineNameNotIn(List<String> values) {
            if (values.size() == 1) {
                return andProductDefineNameNotEqualTo(values.get(0));
            } else {
                addCriterion(IProductRoleDefineDAO.ProductDefineName +
                    " not in", values, "productDefineName");

                return this;
            }
        }

        public Criteria andProductDefineNameIn(String[] values) {
            if (values.length == 1) {
                return andProductDefineNameEqualTo(values[0]);
            } else {
                addCriterion(IProductRoleDefineDAO.ProductDefineName + " in",
                    Arrays.asList(values), "productDefineName");

                return this;
            }
        }

        public Criteria andProductDefineNameNotIn(String[] values) {
            if (values.length == 1) {
                return andProductDefineNameNotEqualTo(values[0]);
            } else {
                addCriterion(IProductRoleDefineDAO.ProductDefineName +
                    " not in", Arrays.asList(values), "productDefineName");

                return this;
            }
        }

        public Criteria andProductDefineNameIn(BaseQueryBean subQueryBean,
            IDataAccessInterface<?, ?> dao) {
            addCriterion(IProductRoleDefineDAO.ProductDefineName + " in ",
                subQueryBean, dao);

            return this;
        }

        public Criteria andProductDefineNameNotIn(BaseQueryBean subQueryBean,
            IDataAccessInterface<?, ?> dao) {
            addCriterion(IProductRoleDefineDAO.ProductDefineName + " not in ",
                subQueryBean, dao);

            return this;
        }

        public Criteria andProductDefineNameBetween(String value1, String value2) {
            addCriterion(IProductRoleDefineDAO.ProductDefineName + " between",
                value1, value2, "productDefineName");

            return this;
        }

        public Criteria andProductDefineNameNotBetween(String value1,
            String value2) {
            addCriterion(IProductRoleDefineDAO.ProductDefineName +
                " not between", value1, value2, "productDefineName");

            return this;
        }

        public Criteria andProductDefineStatusIsNull() {
            addCriterion(IProductRoleDefineDAO.ProductDefineStatus +
                " is null");

            return this;
        }

        public Criteria andProductDefineStatusIsNotNull() {
            addCriterion(IProductRoleDefineDAO.ProductDefineStatus +
                " is not null");

            return this;
        }

        public Criteria andProductDefineStatusIsNotEmpty() {
            addCriterion(IProductRoleDefineDAO.ProductDefineStatus +
                " is not null AND " +
                IProductRoleDefineDAO.ProductDefineStatus + " <> ''");

            return this;
        }

        public Criteria andProductDefineStatusIsEmpty() {
            addCriterion("(" + IProductRoleDefineDAO.ProductDefineStatus +
                " is null OR " + IProductRoleDefineDAO.ProductDefineStatus +
                " = '')");

            return this;
        }

        public Criteria andProductDefineStatusEqualTo(String value) {
            addCriterion(IProductRoleDefineDAO.ProductDefineStatus + " = ",
                value, "productDefineStatus");

            return this;
        }

        public Criteria andProductDefineStatusEqualToForeignKey(
            java.lang.String key) {
            StringBuffer str = new StringBuffer(IProductRoleDefineDAO.ProductDefineStatus);
            str.append(" = ").append(key);
            addForeignKeyCriterion(str.toString());

            return this;
        }

        public Criteria andProductDefineStatusEqualTo(
            BaseQueryBean subQueryBean, IDataAccessInterface<?, ?> dao) {
            addCriterion(IProductRoleDefineDAO.ProductDefineStatus + " = ",
                subQueryBean, dao);

            return this;
        }

        public Criteria andProductDefineStatusNotEqualTo(String value) {
            addCriterion(IProductRoleDefineDAO.ProductDefineStatus + " <>",
                value, "productDefineStatus");

            return this;
        }

        public Criteria andProductDefineStatusNotEqualToOrIsNull(String value) {
            addCriterion(IProductRoleDefineDAO.ProductDefineStatus +
                " is null OR " + IProductRoleDefineDAO.ProductDefineStatus +
                " <>", value, "productDefineStatus");

            return this;
        }

        public Criteria andProductDefineStatusNotEqualToForeignKey(
            java.lang.String key) {
            StringBuffer str = new StringBuffer(IProductRoleDefineDAO.ProductDefineStatus);
            str.append(" <> ").append(key);
            addForeignKeyCriterion(str.toString());

            return this;
        }

        public Criteria andProductDefineStatusNotEqualTo(
            BaseQueryBean subQueryBean, IDataAccessInterface<?, ?> dao) {
            addCriterion(IProductRoleDefineDAO.ProductDefineStatus + " <> ",
                subQueryBean, dao);

            return this;
        }

        public Criteria andProductDefineStatusGreaterThan(String value) {
            addCriterion(IProductRoleDefineDAO.ProductDefineStatus + " >",
                value, "productDefineStatus");

            return this;
        }

        public Criteria andProductDefineStatusGreaterThanForeignKey(
            java.lang.String key) {
            StringBuffer str = new StringBuffer(IProductRoleDefineDAO.ProductDefineStatus);
            str.append(" > ").append(key);
            addForeignKeyCriterion(str.toString());

            return this;
        }

        public Criteria andProductDefineStatusGreaterThan(
            BaseQueryBean subQueryBean, IDataAccessInterface<?, ?> dao) {
            addCriterion(IProductRoleDefineDAO.ProductDefineStatus + " > ",
                subQueryBean, dao);

            return this;
        }

        public Criteria andProductDefineStatusGreaterThanOrEqualTo(String value) {
            addCriterion(IProductRoleDefineDAO.ProductDefineStatus + " >=",
                value, "productDefineStatus");

            return this;
        }

        public Criteria andProductDefineStatusGreaterThanOrEqualToForeignKey(
            java.lang.String key) {
            StringBuffer str = new StringBuffer(IProductRoleDefineDAO.ProductDefineStatus);
            str.append(" >= ").append(key);
            addForeignKeyCriterion(str.toString());

            return this;
        }

        public Criteria andProductDefineStatusGreaterThanOrEqualTo(
            BaseQueryBean subQueryBean, IDataAccessInterface<?, ?> dao) {
            addCriterion(IProductRoleDefineDAO.ProductDefineStatus + " >= ",
                subQueryBean, dao);

            return this;
        }

        public Criteria andProductDefineStatusLessThan(String value) {
            addCriterion(IProductRoleDefineDAO.ProductDefineStatus + " <",
                value, "productDefineStatus");

            return this;
        }

        public Criteria andProductDefineStatusLessThanForeignKey(
            java.lang.String key) {
            StringBuffer str = new StringBuffer(IProductRoleDefineDAO.ProductDefineStatus);
            str.append(" < ").append(key);
            addForeignKeyCriterion(str.toString());

            return this;
        }

        public Criteria andProductDefineStatusLessThan(
            BaseQueryBean subQueryBean, IDataAccessInterface<?, ?> dao) {
            addCriterion(IProductRoleDefineDAO.ProductDefineStatus + " < ",
                subQueryBean, dao);

            return this;
        }

        public Criteria andProductDefineStatusLessThanOrEqualTo(String value) {
            addCriterion(IProductRoleDefineDAO.ProductDefineStatus + " <=",
                value, "productDefineStatus");

            return this;
        }

        public Criteria andProductDefineStatusLessThanOrEqualToForeignKey(
            java.lang.String key) {
            StringBuffer str = new StringBuffer(IProductRoleDefineDAO.ProductDefineStatus);
            str.append(" <= ").append(key);
            addForeignKeyCriterion(str.toString());

            return this;
        }

        public Criteria andProductDefineStatusLessThanOrEqualTo(
            BaseQueryBean subQueryBean, IDataAccessInterface<?, ?> dao) {
            addCriterion(IProductRoleDefineDAO.ProductDefineStatus + " <= ",
                subQueryBean, dao);

            return this;
        }

        public Criteria andProductDefineStatusLike(String value) {
            StringBuffer buffer = new StringBuffer("%");
            buffer.append(value);
            buffer.append("%");
            addCriterion(IProductRoleDefineDAO.ProductDefineStatus + " like",
                buffer.toString(), "productDefineStatus");

            return this;
        }

        public Criteria andProductDefineStatusNotLike(String value) {
            StringBuffer buffer = new StringBuffer("%");
            buffer.append(value);
            buffer.append("%");
            addCriterion(IProductRoleDefineDAO.ProductDefineStatus +
                " not like", buffer.toString(), "productDefineStatus");

            return this;
        }

        public Criteria andProductDefineStatusIn(List<String> values) {
            if (values.size() == 1) {
                return andProductDefineStatusEqualTo(values.get(0));
            } else {
                addCriterion(IProductRoleDefineDAO.ProductDefineStatus + " in",
                    values, "productDefineStatus");

                return this;
            }
        }

        public Criteria andProductDefineStatusNotIn(List<String> values) {
            if (values.size() == 1) {
                return andProductDefineStatusNotEqualTo(values.get(0));
            } else {
                addCriterion(IProductRoleDefineDAO.ProductDefineStatus +
                    " not in", values, "productDefineStatus");

                return this;
            }
        }

        public Criteria andProductDefineStatusIn(String[] values) {
            if (values.length == 1) {
                return andProductDefineStatusEqualTo(values[0]);
            } else {
                addCriterion(IProductRoleDefineDAO.ProductDefineStatus + " in",
                    Arrays.asList(values), "productDefineStatus");

                return this;
            }
        }

        public Criteria andProductDefineStatusNotIn(String[] values) {
            if (values.length == 1) {
                return andProductDefineStatusNotEqualTo(values[0]);
            } else {
                addCriterion(IProductRoleDefineDAO.ProductDefineStatus +
                    " not in", Arrays.asList(values), "productDefineStatus");

                return this;
            }
        }

        public Criteria andProductDefineStatusIn(BaseQueryBean subQueryBean,
            IDataAccessInterface<?, ?> dao) {
            addCriterion(IProductRoleDefineDAO.ProductDefineStatus + " in ",
                subQueryBean, dao);

            return this;
        }

        public Criteria andProductDefineStatusNotIn(
            BaseQueryBean subQueryBean, IDataAccessInterface<?, ?> dao) {
            addCriterion(IProductRoleDefineDAO.ProductDefineStatus +
                " not in ", subQueryBean, dao);

            return this;
        }

        public Criteria andProductDefineStatusBetween(String value1,
            String value2) {
            addCriterion(IProductRoleDefineDAO.ProductDefineStatus +
                " between", value1, value2, "productDefineStatus");

            return this;
        }

        public Criteria andProductDefineStatusNotBetween(String value1,
            String value2) {
            addCriterion(IProductRoleDefineDAO.ProductDefineStatus +
                " not between", value1, value2, "productDefineStatus");

            return this;
        }

        public Criteria andProductDefineCodeIsNull() {
            addCriterion(IProductRoleDefineDAO.ProductDefineCode + " is null");

            return this;
        }

        public Criteria andProductDefineCodeIsNotNull() {
            addCriterion(IProductRoleDefineDAO.ProductDefineCode +
                " is not null");

            return this;
        }

        public Criteria andProductDefineCodeIsNotEmpty() {
            addCriterion(IProductRoleDefineDAO.ProductDefineCode +
                " is not null AND " + IProductRoleDefineDAO.ProductDefineCode +
                " <> ''");

            return this;
        }

        public Criteria andProductDefineCodeIsEmpty() {
            addCriterion("(" + IProductRoleDefineDAO.ProductDefineCode +
                " is null OR " + IProductRoleDefineDAO.ProductDefineCode +
                " = '')");

            return this;
        }

        public Criteria andProductDefineCodeEqualTo(String value) {
            addCriterion(IProductRoleDefineDAO.ProductDefineCode + " = ",
                value, "productDefineCode");

            return this;
        }

        public Criteria andProductDefineCodeEqualToForeignKey(
            java.lang.String key) {
            StringBuffer str = new StringBuffer(IProductRoleDefineDAO.ProductDefineCode);
            str.append(" = ").append(key);
            addForeignKeyCriterion(str.toString());

            return this;
        }

        public Criteria andProductDefineCodeEqualTo(
            BaseQueryBean subQueryBean, IDataAccessInterface<?, ?> dao) {
            addCriterion(IProductRoleDefineDAO.ProductDefineCode + " = ",
                subQueryBean, dao);

            return this;
        }

        public Criteria andProductDefineCodeNotEqualTo(String value) {
            addCriterion(IProductRoleDefineDAO.ProductDefineCode + " <>",
                value, "productDefineCode");

            return this;
        }

        public Criteria andProductDefineCodeNotEqualToOrIsNull(String value) {
            addCriterion(IProductRoleDefineDAO.ProductDefineCode +
                " is null OR " + IProductRoleDefineDAO.ProductDefineCode +
                " <>", value, "productDefineCode");

            return this;
        }

        public Criteria andProductDefineCodeNotEqualToForeignKey(
            java.lang.String key) {
            StringBuffer str = new StringBuffer(IProductRoleDefineDAO.ProductDefineCode);
            str.append(" <> ").append(key);
            addForeignKeyCriterion(str.toString());

            return this;
        }

        public Criteria andProductDefineCodeNotEqualTo(
            BaseQueryBean subQueryBean, IDataAccessInterface<?, ?> dao) {
            addCriterion(IProductRoleDefineDAO.ProductDefineCode + " <> ",
                subQueryBean, dao);

            return this;
        }

        public Criteria andProductDefineCodeGreaterThan(String value) {
            addCriterion(IProductRoleDefineDAO.ProductDefineCode + " >", value,
                "productDefineCode");

            return this;
        }

        public Criteria andProductDefineCodeGreaterThanForeignKey(
            java.lang.String key) {
            StringBuffer str = new StringBuffer(IProductRoleDefineDAO.ProductDefineCode);
            str.append(" > ").append(key);
            addForeignKeyCriterion(str.toString());

            return this;
        }

        public Criteria andProductDefineCodeGreaterThan(
            BaseQueryBean subQueryBean, IDataAccessInterface<?, ?> dao) {
            addCriterion(IProductRoleDefineDAO.ProductDefineCode + " > ",
                subQueryBean, dao);

            return this;
        }

        public Criteria andProductDefineCodeGreaterThanOrEqualTo(String value) {
            addCriterion(IProductRoleDefineDAO.ProductDefineCode + " >=",
                value, "productDefineCode");

            return this;
        }

        public Criteria andProductDefineCodeGreaterThanOrEqualToForeignKey(
            java.lang.String key) {
            StringBuffer str = new StringBuffer(IProductRoleDefineDAO.ProductDefineCode);
            str.append(" >= ").append(key);
            addForeignKeyCriterion(str.toString());

            return this;
        }

        public Criteria andProductDefineCodeGreaterThanOrEqualTo(
            BaseQueryBean subQueryBean, IDataAccessInterface<?, ?> dao) {
            addCriterion(IProductRoleDefineDAO.ProductDefineCode + " >= ",
                subQueryBean, dao);

            return this;
        }

        public Criteria andProductDefineCodeLessThan(String value) {
            addCriterion(IProductRoleDefineDAO.ProductDefineCode + " <", value,
                "productDefineCode");

            return this;
        }

        public Criteria andProductDefineCodeLessThanForeignKey(
            java.lang.String key) {
            StringBuffer str = new StringBuffer(IProductRoleDefineDAO.ProductDefineCode);
            str.append(" < ").append(key);
            addForeignKeyCriterion(str.toString());

            return this;
        }

        public Criteria andProductDefineCodeLessThan(
            BaseQueryBean subQueryBean, IDataAccessInterface<?, ?> dao) {
            addCriterion(IProductRoleDefineDAO.ProductDefineCode + " < ",
                subQueryBean, dao);

            return this;
        }

        public Criteria andProductDefineCodeLessThanOrEqualTo(String value) {
            addCriterion(IProductRoleDefineDAO.ProductDefineCode + " <=",
                value, "productDefineCode");

            return this;
        }

        public Criteria andProductDefineCodeLessThanOrEqualToForeignKey(
            java.lang.String key) {
            StringBuffer str = new StringBuffer(IProductRoleDefineDAO.ProductDefineCode);
            str.append(" <= ").append(key);
            addForeignKeyCriterion(str.toString());

            return this;
        }

        public Criteria andProductDefineCodeLessThanOrEqualTo(
            BaseQueryBean subQueryBean, IDataAccessInterface<?, ?> dao) {
            addCriterion(IProductRoleDefineDAO.ProductDefineCode + " <= ",
                subQueryBean, dao);

            return this;
        }

        public Criteria andProductDefineCodeLike(String value) {
            StringBuffer buffer = new StringBuffer("%");
            buffer.append(value);
            buffer.append("%");
            addCriterion(IProductRoleDefineDAO.ProductDefineCode + " like",
                buffer.toString(), "productDefineCode");

            return this;
        }

        public Criteria andProductDefineCodeNotLike(String value) {
            StringBuffer buffer = new StringBuffer("%");
            buffer.append(value);
            buffer.append("%");
            addCriterion(IProductRoleDefineDAO.ProductDefineCode + " not like",
                buffer.toString(), "productDefineCode");

            return this;
        }

        public Criteria andProductDefineCodeIn(List<String> values) {
            if (values.size() == 1) {
                return andProductDefineCodeEqualTo(values.get(0));
            } else {
                addCriterion(IProductRoleDefineDAO.ProductDefineCode + " in",
                    values, "productDefineCode");

                return this;
            }
        }

        public Criteria andProductDefineCodeNotIn(List<String> values) {
            if (values.size() == 1) {
                return andProductDefineCodeNotEqualTo(values.get(0));
            } else {
                addCriterion(IProductRoleDefineDAO.ProductDefineCode +
                    " not in", values, "productDefineCode");

                return this;
            }
        }

        public Criteria andProductDefineCodeIn(String[] values) {
            if (values.length == 1) {
                return andProductDefineCodeEqualTo(values[0]);
            } else {
                addCriterion(IProductRoleDefineDAO.ProductDefineCode + " in",
                    Arrays.asList(values), "productDefineCode");

                return this;
            }
        }

        public Criteria andProductDefineCodeNotIn(String[] values) {
            if (values.length == 1) {
                return andProductDefineCodeNotEqualTo(values[0]);
            } else {
                addCriterion(IProductRoleDefineDAO.ProductDefineCode +
                    " not in", Arrays.asList(values), "productDefineCode");

                return this;
            }
        }

        public Criteria andProductDefineCodeIn(BaseQueryBean subQueryBean,
            IDataAccessInterface<?, ?> dao) {
            addCriterion(IProductRoleDefineDAO.ProductDefineCode + " in ",
                subQueryBean, dao);

            return this;
        }

        public Criteria andProductDefineCodeNotIn(BaseQueryBean subQueryBean,
            IDataAccessInterface<?, ?> dao) {
            addCriterion(IProductRoleDefineDAO.ProductDefineCode + " not in ",
                subQueryBean, dao);

            return this;
        }

        public Criteria andProductDefineCodeBetween(String value1, String value2) {
            addCriterion(IProductRoleDefineDAO.ProductDefineCode + " between",
                value1, value2, "productDefineCode");

            return this;
        }

        public Criteria andProductDefineCodeNotBetween(String value1,
            String value2) {
            addCriterion(IProductRoleDefineDAO.ProductDefineCode +
                " not between", value1, value2, "productDefineCode");

            return this;
        }
    }
}
